home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 18156 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.2 KB  |  37 lines

  1. Path: news.iadfw.net!usenet
  2. From: Mark Nelson <markn@airmail.net>
  3. Newsgroups: comp.lang.c,comp.lang.c++
  4. Subject: Re: calling 16 bit DLL from 32-bit C/C++ program?
  5. Date: Thu, 18 Apr 1996 22:17:10 -0500
  6. Organization: customer of Internet America
  7. Message-ID: <317705B6.1241@airmail.net>
  8. References: <4l4die$i7q@vixen.cso.uiuc.edu>
  9. NNTP-Posting-Host: dal17-02.ppp.iadfw.net
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=iso-8859-1
  12. Content-Transfer-Encoding: 8bit
  13. X-Mailer: Mozilla 2.0GoldB2 (Win95; I)
  14.  
  15. Baogang Yao wrote:
  16. > Does anybody know whether it's possible to call a 16-bit DLL from a
  17. > 32bit C/C++ application? I am using Microsoft Visual C++4.0, and I
  18. > have to call a 16 bit DLL.
  19. > Any suggestions will be helpful. Thanks in advance.
  20. > Baogang Yao
  21. > b¡yao@cs.uiuc.edu
  22.  
  23. Yes, it is possible.  You need to look in your online help for
  24. documentation on the Universal Thunk Layer.  Microsoft provides
  25. some DLLs with a very small API that you use. 
  26.  
  27. The downside to all this is that you have to write an
  28. interface to handle all the parameter passing.  The MS code
  29. takes care of converting pointers from 32 bits down to 16:16,
  30. but it doesn't give you much more help than that.
  31.  
  32. Mark Nelson
  33. http://web2.airmail.net/markn
  34.